\hypertarget{classduye_1_1_xml_visitor}{\section{duye\-:\-:Xml\-Visitor Class Reference}
\label{classduye_1_1_xml_visitor}\index{duye\-::\-Xml\-Visitor@{duye\-::\-Xml\-Visitor}}
}


Implements the interface to the \char`\"{}\-Visitor pattern\char`\"{} (see the Accept() method.) If you call the Accept() method, it requires being passed a \hyperlink{classduye_1_1_xml_visitor}{Xml\-Visitor} class to handle callbacks. For nodes that contain other nodes (Document, Element) you will get called with a Visit\-Enter/\-Visit\-Exit pair. Nodes that are always leaves are simply called with Visit().  




{\ttfamily \#include $<$duye\-\_\-xml.\-h$>$}

Inheritance diagram for duye\-:\-:Xml\-Visitor\-:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[height=2.000000cm]{classduye_1_1_xml_visitor}
\end{center}
\end{figure}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classduye_1_1_xml_visitor_a98f4ec3a62fca202d5ca357249cfc7ce}{virtual bool \hyperlink{classduye_1_1_xml_visitor_a98f4ec3a62fca202d5ca357249cfc7ce}{visit\-Enter} (const \hyperlink{classduye_1_1_xml_document}{Xml\-Document} \&)}\label{classduye_1_1_xml_visitor_a98f4ec3a62fca202d5ca357249cfc7ce}

\begin{DoxyCompactList}\small\item\em Visit a document. \end{DoxyCompactList}\item 
\hypertarget{classduye_1_1_xml_visitor_acac3f70e298fb825327d7bf0cfd87651}{virtual bool \hyperlink{classduye_1_1_xml_visitor_acac3f70e298fb825327d7bf0cfd87651}{visit\-Exit} (const \hyperlink{classduye_1_1_xml_document}{Xml\-Document} \&)}\label{classduye_1_1_xml_visitor_acac3f70e298fb825327d7bf0cfd87651}

\begin{DoxyCompactList}\small\item\em Visit a document. \end{DoxyCompactList}\item 
\hypertarget{classduye_1_1_xml_visitor_a9b9a0abd70e1724ea4d8d6de512928ce}{virtual bool \hyperlink{classduye_1_1_xml_visitor_a9b9a0abd70e1724ea4d8d6de512928ce}{visit\-Enter} (const \hyperlink{classduye_1_1_xml_element}{Xml\-Element} \&, const \hyperlink{classduye_1_1_xml_attribute}{Xml\-Attribute} $\ast$)}\label{classduye_1_1_xml_visitor_a9b9a0abd70e1724ea4d8d6de512928ce}

\begin{DoxyCompactList}\small\item\em Visit an element. \end{DoxyCompactList}\item 
\hypertarget{classduye_1_1_xml_visitor_a07f65fb94df4da056b508d8d43b08492}{virtual bool \hyperlink{classduye_1_1_xml_visitor_a07f65fb94df4da056b508d8d43b08492}{visit\-Exit} (const \hyperlink{classduye_1_1_xml_element}{Xml\-Element} \&)}\label{classduye_1_1_xml_visitor_a07f65fb94df4da056b508d8d43b08492}

\begin{DoxyCompactList}\small\item\em Visit an element. \end{DoxyCompactList}\item 
\hypertarget{classduye_1_1_xml_visitor_a9a405f40e1300de455fc05712cd98203}{virtual bool \hyperlink{classduye_1_1_xml_visitor_a9a405f40e1300de455fc05712cd98203}{visit} (const \hyperlink{classduye_1_1_xml_declaration}{Xml\-Declaration} \&)}\label{classduye_1_1_xml_visitor_a9a405f40e1300de455fc05712cd98203}

\begin{DoxyCompactList}\small\item\em Visit a declaration. \end{DoxyCompactList}\item 
\hypertarget{classduye_1_1_xml_visitor_a5994fbfcbdb289527393e3695e21b3fb}{virtual bool \hyperlink{classduye_1_1_xml_visitor_a5994fbfcbdb289527393e3695e21b3fb}{visit} (const \hyperlink{classduye_1_1_xml_text}{Xml\-Text} \&)}\label{classduye_1_1_xml_visitor_a5994fbfcbdb289527393e3695e21b3fb}

\begin{DoxyCompactList}\small\item\em Visit a text node. \end{DoxyCompactList}\item 
\hypertarget{classduye_1_1_xml_visitor_a3cef74e4d3a171c1f528225af3fccb80}{virtual bool \hyperlink{classduye_1_1_xml_visitor_a3cef74e4d3a171c1f528225af3fccb80}{visit} (const \hyperlink{classduye_1_1_xml_comment}{Xml\-Comment} \&)}\label{classduye_1_1_xml_visitor_a3cef74e4d3a171c1f528225af3fccb80}

\begin{DoxyCompactList}\small\item\em Visit a comment node. \end{DoxyCompactList}\item 
\hypertarget{classduye_1_1_xml_visitor_a59cb2c3a4d18c8d9be51d9c13f0109cf}{virtual bool \hyperlink{classduye_1_1_xml_visitor_a59cb2c3a4d18c8d9be51d9c13f0109cf}{visit} (const \hyperlink{classduye_1_1_xml_unknown}{Xml\-Unknown} \&)}\label{classduye_1_1_xml_visitor_a59cb2c3a4d18c8d9be51d9c13f0109cf}

\begin{DoxyCompactList}\small\item\em Visit an unknown node. \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
Implements the interface to the \char`\"{}\-Visitor pattern\char`\"{} (see the Accept() method.) If you call the Accept() method, it requires being passed a \hyperlink{classduye_1_1_xml_visitor}{Xml\-Visitor} class to handle callbacks. For nodes that contain other nodes (Document, Element) you will get called with a Visit\-Enter/\-Visit\-Exit pair. Nodes that are always leaves are simply called with Visit(). 

If you return 'true' from a Visit method, recursive parsing will continue. If you return false, {\bfseries no children of this node or its sibilings} will be Visited.

All flavors of Visit methods have a default implementation that returns 'true' (continue visiting). You need to only override methods that are interesting to you.

Generally Accept() is called on the G\-Xml\-Document, although all nodes suppert Visiting.

You should never change the document from a callback. see Xml\-Node\-::\-Accept() 

The documentation for this class was generated from the following file\-:\begin{DoxyCompactItemize}
\item 
Z\-:/duye/src/duyebase/utils/duye\-\_\-xml.\-h\end{DoxyCompactItemize}
